declare const array: string[];

for (const x of array) {
  console.log(x);
}

for (let i = 0; i < array.length; i++) {
  // i is used, so for-of could not be used.
  console.log(`${i}-${array[i]}`);
}

for (let i = 0; i < arr1.length; i++) {
  const x = arr1[i] === arr2[i];
}

for (var c = 0; c < arr.length; c++) {
  doMath(c);
}

for (var e = 0; e < arr.length; e++) {
  if (e > 5) {
    doMath(e);
  }
  console.log(arr[e]);
}

var m = 0;
for (;;) {
  if (m > 3) break;
  console.log(m);
  m++;
}

var o = 0;
for (; o < arr.length; o++) {
  console.log(arr[o]);
}

for (let x = 0; x <= arr.length; x++) {}

for (var q in obj) {
  if (obj.hasOwnProperty(q)) {
    console.log(q);
  }
}

for (var d = 0; d < arr?.length; d++) doMath(d);